package com.neusoft.controller.registration;

import com.neusoft.service.EmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/employees")
//@CrossOrigin
public class EmployeeController {

    @Autowired
    EmployeeService employeeService;

    @GetMapping("/getDoctorByDeptIdAndLevelId")
    public List<Map<String,Object>> getDoctorByDeptIdAndLevelId(Integer departmentId,Integer registLevelId){
        List<Map<String,Object>> list=employeeService.getDoctorByDeptIdAndLevelId(departmentId,registLevelId);
        return list;
    }
    @GetMapping("/getCheckDoctorByDeptId")
    public List<Map<String,Object>> getCheckDoctorByDeptId(Integer departmentId){
        List<Map<String,Object>> list=employeeService.getCheckDoctorByDeptId(departmentId);
        return list;
    }
    @GetMapping("/getInpectionDoctorByDeptId")
    public List<Map<String,Object>> getInpectionDoctorByDeptId(Integer departmentId){
        List<Map<String,Object>> list=employeeService.getInspectionDoctorByDeptId(departmentId);
        return list;
    }
    @GetMapping("/getDisaposalDoctorByDeptId")
    public List<Map<String,Object>> getDisposalDoctorByDeptId(Integer departmentId){
        List<Map<String,Object>> list=employeeService.getDisposalDoctorByDeptId(departmentId);
        return list;
    }
}
